home *** CD-ROM | disk | FTP | other *** search
/ Easy Baby Massage / Easy Baby Massage.iso / pc / content / main.dcr / Internal_104_preLoad2.ls < prev    next >
Encoding:
Text File  |  2007-04-22  |  884 b   |  37 lines

  1. property chapter, n
  2.  
  3. on beginSprite me
  4.   n = member(1, "external files").line.count
  5.   n = n / 2
  6.   chapter = []
  7.   repeat with i = 1 to n
  8.     if the machineType = 256 then
  9.       chapter[i] = preloadNetThing(the moviePath & "chapter\cp" & i & ".txt")
  10.       next repeat
  11.     end if
  12.     chapter[i] = preloadNetThing(the moviePath & "chapter:cp" & i & ".txt")
  13.   end repeat
  14. end
  15.  
  16. on exitFrame me
  17.   allloaded = 1
  18.   repeat with i = 1 to n
  19.     if netDone(chapter[i]) = 0 then
  20.       allloaded = 0
  21.     end if
  22.   end repeat
  23.   if allloaded then
  24.     repeat with i = 1 to n
  25.       if the machineType = 256 then
  26.         importFileInto(member(i, "chapter"), the moviePath & "chapter\cp" & i & ".txt")
  27.         next repeat
  28.       end if
  29.       importFileInto(member(i, "chapter"), the moviePath & "chapter:cp" & i & ".txt")
  30.     end repeat
  31.     preparemainmenu()
  32.     go(12)
  33.   else
  34.     go(the frame)
  35.   end if
  36. end
  37.